package com.yc.service.xcx.user.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.yc.dao.DaoSupport;
import com.yc.entity.Page;
import com.yc.service.xcx.base.XCXBaseService;
import com.yc.service.xcx.user.INormalUser;
import com.yc.util.PageData;

@Service
public class NormalUserService extends XCXBaseService implements INormalUser {

	

	@Resource(name = "daoSupport")
	private DaoSupport dao;

	
	@Override
	public void save(PageData pd) throws Exception {
		// TODO Auto-generated method stub
		dao.save("XCXNormalUserMapper.save", pd);
	}

	@Override
	public void delete(PageData pd) throws Exception {
		// TODO Auto-generated method stub
		dao.delete("XCXNormalUserMapper.delete", pd);
	}

	@Override
	public void edit(PageData pd) throws Exception {
		// TODO Auto-generated method stub
		dao.update("XCXNormalUserMapper.edit", pd);
	}

	@Override
	public PageData findById(PageData pd) throws Exception {
		// TODO Auto-generated method stub
		return (PageData) dao.findForObject("XCXNormalUserMapper.findById", pd);
	}
	
	@Override
	public PageData getAppUserCount(String pd) throws Exception {
		// TODO Auto-generated method stub
		return (PageData) dao.findForObject("XCXNormalUserMapper.getAppUserCount", pd);
	}

	@Override
	public List<PageData> list(Page page) throws Exception {
		// TODO Auto-generated method stub
		return (List<PageData>) dao.findForList("XCXNormalUserMapper.normalUserlistPage", page);
	}

	@Override
	public PageData findByUId(PageData pd) throws Exception {
		// TODO Auto-generated method stub
		return (PageData) dao.findForObject("XCXNormalUserMapper.findByUId", pd);
	}

}
